package com.example.entity;

import com.baomidou.mybatisplus.annotation.SqlCondition;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.time.LocalDateTime;

/**
 * @author Jxx
 * @create 2021-08-15 14:21
 */
@NoArgsConstructor
@AllArgsConstructor
@Data
//@TableName("mp_user")
public class User {
    //@TableId(value = "id")
    private Long id;
   // @TableField(value = "name")
    @TableField(condition = SqlCondition.LIKE)
    private String Name;
    @TableField(condition = "%s&lt;#{%s}")
    private Integer age;
    private String email;
    private Long managerId;
    private LocalDateTime createTime;
    // 测试变量不在数据库中的问题
    // 1.使用transient关键字
    // 2.使用static关键字
    // 3.使用@TableField(exist = false)
    @TableField(exist = false)
    private  String remark;
}
